<%--
  Created by IntelliJ IDEA.
  User: 梁玉杰
  Date: 2021/7/16
  Time: 15:20
  To change this template use File | Settings | File Templates.
--%>
<%@ page contentType="text/html;charset=UTF-8" language="java" %>
<html>
<head>
    <meta charset="utf-8">
    <title></title>
    <%--Layui的js--%>
    <script type="text/javascript"
            src="${pageContext.request.contextPath}/libs/layui/layui.js"
            charset="utf-8"></script>
<%--Layui的css--%>
    <link rel="stylesheet"
          href="${pageContext.request.contextPath}/libs/layui/css/layui.css"
          media="all">
    <style>
        .layui-table-cell .layui-form-checkbox[lay-skin="primary"]{
            top: 50%;
            transform: translateY(-50%);
        }
        .layui-table-cell{    height: 39px;
            line-height: 36px;}
    </style>
</head>
<body>

<%--是js获取到项目名称--%>
    <div>
        <input id="basePath" hidden value="${pageContext.request.contextPath}"/>
    </div>


<%-- 数据表格开始 --%>
<div>
    <%-- 表格 --%>
    <table class="layui-hide" id="studentTable" lay-filter="studentTable" style="height:150px" ></table>

    <%-- 头部工具栏 --%>
    <script type="text/html" id="studentToolbar">
        <div class="layui-btn-container">

            <button class="layui-btn layui-btn-sm" lay-event="add"><i class="layui-icon layui-icon-add-circle"></i>添加商品</button>
        </div>
    </script>

    <%-- 行工具栏 --%>
    <script type="text/html" id="barDemo">


        <button type="button" class="layui-btn layui-btn-warm layui-btn-radius" lay-event="delete" ><i class="layui-icon layui-icon-delete"></i>删除</button>
    </script>

</div>


<!-- 添加和修改商品的弹出层开始 -->
<div id="addOrUpdateBillDiv" style="display: none;margin: 10px;">
    <form id="dataFrm1" method="post" class="layui-form layui-form-pane " lay-filter="dataFrm1">
        <!-- 隐藏域，保存当前账单的ID -->
        <input type="hidden" name="pkId" id="pkId">

        <div class="layui-form-item">
            <label class="layui-form-label">商品名称：</label>
            <div class="layui-input-block">
                <input type="text" name="goodsName" id="goodsName"  placeholder="请输入名称" autocomplete="off" class="layui-input">
            </div>
        </div>

        <div class="layui-form-item">
            <label class="layui-form-label">商品类型：</label>
            <div class="layui-input-block">
                <select name="goodsType" id="goodsType" >
                    <option value='' >请选择</option>
                    <option value='11'>蔬菜</option>
                    <option value='12'>水果</option>
                    <option value='13'>副食品</option>
                    <option value='14'>日用品</option>
                </select>
            </div>
        </div>

        <div class="layui-form-item">
            <label class="layui-form-label">数量：</label>
            <div class="layui-input-block">
                <input type="text" name="goodsAmount" id="goodsAmount" placeholder="请输入数量" autocomplete="off" class="layui-input">
            </div>
        </div>



        <div class="layui-form-item" style="text-align: center;">
            <button type="button" class="layui-btn" lay-submit lay-filter="doSubmit">确认添加</button>
            <button type="reset" class="layui-btn layui-btn-primary">重置</button>
        </div>
    </form>
</div>
<!-- 添加和修改商品的弹出层结束-->



<%--jquery的js--%>
<script type="text/javascript"
        src="${pageContext.request.contextPath}/libs/jquery/jquery-3.5.1.js"></script>
<%--引入自己的JS代码--%>
<script type="text/javascript"
        src="${pageContext.request.contextPath}/static/js/student/splist.js"></script>


</body>
</html>
